package ch.fhnw.qualiscan;

import ch.fhnw.qualiscan.core.libraries.LayoutLib;

import com.vaadin.ui.Panel;

import eu.livotov.tpt.TPTApplication;

/**
 * AppLoader instantiates all the core-libraries. It also loads the default page.
 * 
 * @author Kevin Mettenberger, Benjamin Groehbiel
 *
 */

@SuppressWarnings("serial")
public class AppLoader extends Panel {

	private LayoutLib layoutLib;
	
	private AppObject appObject;
	
	/**
	 * Load the libraries, which have not yet been loaded.
	 * @see ch.fhnw.qualiscan.core.libraries
	 */
	public void load() {
		layoutLib = new LayoutLib();
		appObject = (AppObject) TPTApplication.getCurrentApplication().getMainWindow().getData();
	}
	
	/**
	 * prepare everything for the UI.
	 */
	public void init() {
		layoutLib.init();
	}
	
}
